<template>
  <div class="leteuser">
<router-view/>
  </div>
</template>

<script>
import api from "../axios/api/api";
export default {
  beforeCreate () {
         console.log(1);
     api.usernameObj().then((data) => {
      this.$notify({
        title: "欢迎回来",
        add:1,
        type: "success",
        message: '你好  '+data.data.data.name,
      });
      localStorage.setItem('username',data.data.data.name)
 
    });
  }
};
</script>

<style lang="scss" scoped>
</style>